long count(string file){//除了空格和换行都算字符 
	char c;
	long number=0;
	ifstream infile; 
    infile.open(file.data()); 
    assert(infile.is_open()); 
    while (!infile.eof())
    {
        infile>>c;
        number++;
    }
    if(number>=2) number--;
    infile.close();
	return number;
}
long word(string file){//除了被-隔开的都算单词 
	char c;
	long number=0;
	int temp=0;
	ifstream infile; 
    infile.open(file.data()); 
    assert(infile.is_open()); 
    infile >> noskipws;
    while (!infile.eof())
    {
        infile>>c;
        if(65<=c&&c<=122&&temp==0){
        	temp++;
		}
		if(temp!=0&&c<65&&c!=45){
			number++;
			temp=0;
		}
		if(temp!=0&&c>122){
			number++;
			temp=0;
		}
    }
    if(temp!=0) number++;
    infile.close();
	return number;
}
long sentence(string file){//被.和;隔开的算句子 
	char c;
	long number=0;
	int temp=0;
	ifstream infile; 
    infile.open(file.data()); 
    assert(infile.is_open()); 
    infile >> noskipws;
    while (!infile.eof())
    {
        infile>>c;
        if(65<=c&&c<=122&&temp==0){
        	temp++;
		}
		if(temp!=0&&c==59){
			number++;
			temp=0;
		}
		if(temp!=0&&c==46){
			number++;
			temp=0;
		}
		
    }
    if(temp!=0) number++;
    infile.close();//关闭文件输入流 
	return number;
}